package com.yky.entity;

import java.io.Serializable;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

/**
 * 结局指标
 * 
 * @author vimesly
 * 
 */

@SuppressWarnings("serial")
@Entity
@Table(name = "work_project_indicator_version")
public class ProjectIndicatorVersion implements Serializable {

	private Integer id;
	private String indicatorName; // 名称
	private String indicatorDescription; // 描述
	private String indicatorType; // 结局指标类型

	private String type; // 类型 （0-主要 1-次要 2-其他）

	private Project project; // 所属项目
	private ProjectVersion projectVersion; // 所属项目版本表

	@Id
	@GeneratedValue
	@Column(name = "id", unique = true, nullable = false)
	public Integer getId() {
		return id;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	@Column(name = "indicator_name")
	public String getIndicatorName() {
		return indicatorName;
	}

	public void setIndicatorName(String indicatorName) {
		this.indicatorName = indicatorName;
	}

	@Column(name = "indicator_description")
	public String getIndicatorDescription() {
		return indicatorDescription;
	}

	public void setIndicatorDescription(String indicatorDescription) {
		this.indicatorDescription = indicatorDescription;
	}

	@Column(name = "indicator_type")
	public String getIndicatorType() {
		return indicatorType;
	}

	public void setIndicatorType(String indicatorType) {
		this.indicatorType = indicatorType;
	}

	@Column(name = "type")
	public String getType() {
		return type;
	}

	public void setType(String type) {
		this.type = type;
	}

	@ManyToOne
	@JoinColumn(name = "project_id")
	public Project getProject() {
		return project;
	}

	public void setProject(Project project) {
		this.project = project;
	}
	
	@ManyToOne
	@JoinColumn(name = "project_version_id")
	public ProjectVersion getProjectVersion() {
		return projectVersion;
	}

	public void setProjectVersion(ProjectVersion projectVersion) {
		this.projectVersion = projectVersion;
	}

}
